using IceCS.Puke.Core;
using Xunit;

namespace IceCS.Puke.Test
{
    public class UnitTest1
    {

        [Fact]
        public void GetLastCardTest()
        {
            var deck = new Deck();
            var lastCard = new Card(Suit.Spade, Rank.King);
            deck.LastCardDrawn += (sender, e) =>
              {
                  Assert.Equal(expected: lastCard, actual: e.LastCard);
              };
            deck.GetCard(52);
        }

        [Fact]
        public void CardEqualTest()
        {
            var card1 = new Card(Suit.Heart, Rank.Ace);
            var card2 = card1.CloneCard();

            Assert.True(card1 == card2);

            card1 = null;

            Assert.False(card1 == card2);

            card2 = null;
            Assert.True(card1 == card2);
        }

        [Fact]
        public void TestS()
        {

        }
    }
}
